capture log close
capture noisily log using "R:\Zentrale\ZB-S\Daten_FDSZ_Gastforscher\1_gafo\2016_0133\Table 2.log", replace
capture noisily log using "Table 2.log", replace

**** Load data in Stata
clear all
set more off
set maxvar 5000
capture noisily use "final_sample_03032023_pseudo.dta", clear
capture noisily use "R:\Zentrale\ZB-S\Daten_FDSZ_Gastforscher\1_gafo\2016_0133\data\Bundesbank Discussion Paper\final_sample_03032023.dta", clear



**** Table 2: Summary statistics
**** Overall sample
tabstat abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty, statistics(count mean sd) columns(statistics)
foreach i of varlist abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty {
}

tabstat sanctions enacts, statistics(count mean sd) columns(statistics)
foreach i of varlist sanctions enacts {
}

tabstat am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI, statistics(count mean sd skew) columns(statistics)
foreach i of varlist am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI {
}

tabstat am123 amNOTloans am124 MoneyMKT FIsec am139, statistics(count mean sd skew) columns(statistics)
foreach i of varlist am123 amNOTloans am124 MoneyMKT FIsec am139 {
}

tabstat am100 if abroad_CTRY==0, statistics(count mean sd skew) columns(statistics)

tabstat am100 if abroad_CTRY==1, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notEU_CTRY==1, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notFATF_CTRY==1, statistics(count mean sd skew) columns(statistics)

tabstat lam100, statistics(count mean sd skew) columns(statistics)

**** Subsample for never-sanctioned countries (smallsample==0)
tabstat abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty if smallsample==0, statistics(count mean sd skew ) columns(statistics)
foreach i of varlist abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty {
}

tabstat am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI if smallsample==0, statistics(count mean sd skew ) columns(statistics)
foreach i of varlist am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI {
}

tabstat am123 amNOTloans am124 MoneyMKT FIsec am139 if smallsample==0, statistics(count mean sd skew ) columns(statistics)
foreach i of varlist am123 amNOTloans am124 MoneyMKT FIsec am139 {
}

tabstat am100 if abroad_CTRY==0 & smallsample==0, statistics(count mean sd skew) columns(statistics)

tabstat am100 if abroad_CTRY==1 & smallsample==0, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notEU_CTRY==1 & smallsample==0, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notFATF_CTRY==1 & smallsample==0, statistics(count mean sd skew) columns(statistics)

tabstat lam100 if smallsample==0, statistics(count mean sd skew) columns(statistics)


**** Subsample for at least once-sanctioned countries (smallsample==1)
tabstat abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty if smallsample==1, statistics(count mean sd skew) columns(statistics)
foreach i of varlist abroad_CTRY notEU_CTRY notFATF_CTRY InLandOfCounterparty {
}

tabstat am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI if smallsample==1, statistics(count mean sd skew) columns(statistics)
foreach i of varlist am100 tobanks toINSandOFI toGOV toFIRMSandHHandNPI {
}

tabstat am123 amNOTloans am124 FIsec am139 if smallsample==1, statistics(count mean sd skew) columns(statistics)
foreach i of varlist am123 amNOTloans am124 FIsec am139 {
}

tabstat am100 if abroad_CTRY==0 & smallsample==1, statistics(count mean sd skew) columns(statistics)

tabstat am100 if abroad_CTRY==1 & smallsample==1, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notEU_CTRY==1 & smallsample==1, statistics(count mean sd skew) columns(statistics)

tabstat am100 if notFATF_CTRY==1 & smallsample==1, statistics(count mean sd skew) columns(statistics)

tabstat lam100 if smallsample==1, statistics(count mean sd skew) columns(statistics)

log close
